package com.zg.common.core.dao.autoflow.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.zg.common.core.dao.BaseEntity;
import lombok.Data;

import java.io.Serializable;

/**
 * 
 * @TableName autoflow_step_sealdata
 */
@Data
public class AutoflowStepSealdata extends BaseEntity  {


    /**
     * 流程CODE
     */
    @TableField(value = "FLOW_CODE")
    private String flowCode;

    /**
     * 环节code
     */
    @TableField(value = "STEP_CODE")
    private String stepCode;

    /**
     * 盖章数据
     */
    @TableField(value = "SEAL_DATA")
    private String sealData;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        AutoflowStepSealdata other = (AutoflowStepSealdata) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getFlowCode() == null ? other.getFlowCode() == null : this.getFlowCode().equals(other.getFlowCode()))
            && (this.getStepCode() == null ? other.getStepCode() == null : this.getStepCode().equals(other.getStepCode()))
            && (this.getSealData() == null ? other.getSealData() == null : this.getSealData().equals(other.getSealData()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getFlowCode() == null) ? 0 : getFlowCode().hashCode());
        result = prime * result + ((this.getStepCode() == null) ? 0 : this.getStepCode().hashCode());
        result = prime * result + ((getSealData() == null) ? 0 : getSealData().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", flowCode=").append(flowCode);
        sb.append(", setpCode=").append(stepCode);
        sb.append(", sealData=").append(sealData);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}